package com.polaris.live.dialog

import android.content.Context
import com.lxj.xpopup.XPopup
import com.lxj.xpopup.core.BottomPopupView
import com.polaris.live.R
import com.polaris.live.common.ext.setOnSingleClickListener
import com.polaris.live.databinding.DialogRoomSkinDetailBinding

/**
 * 房间皮肤说明
 *
 * @author Created by 半仙 on 2024/12/23/023 17:55
 */
class RoomSkinDetailDialog(context: Context) : BottomPopupView(context) {

    override fun getImplLayoutId() = R.layout.dialog_room_skin_detail

    private lateinit var mBinding: DialogRoomSkinDetailBinding

    override fun onCreate() {
        super.onCreate()
        mBinding = DialogRoomSkinDetailBinding.bind(popupImplView)
        mBinding.closeImg.setOnSingleClickListener {
            dismiss()
        }
    }

    companion object {

        fun show(context: Context) {
            XPopup.Builder(context)
                .isDestroyOnDismiss(true)
                .asCustom(RoomSkinDetailDialog(context))
                .show()
        }
    }
}